home *** CD-ROM | disk | FTP | other *** search
/ Invisible Universe / Invisible Universe (1995)(Voyager)[Mac-PC].iso / mac / UNIVERSE / SHARED.DIR / 01016_Script_sbt-retracexxx < prev    next >
Text File  |  1995-11-21  |  1KB  |  51 lines

  1. -- standard button trios
  2. --property myNormal, myRollover, myPressed, myChannel, myScript, ancestor
  3.  
  4. --on birth me, no, sp, ro, pr, sc
  5. --  set ancestor to birth(script "sbt",no, sp, ro, pr, sc)
  6. --  set myNormal to (the number of cast no)
  7. --  set myRollover to (the number of cast ro)
  8. --  set myPressed to (the number of cast pr)
  9. --  set myScript to sc
  10. --  set myChannel to integer(sp)
  11. --  return me
  12. --end
  13.  
  14.  
  15. on sbtrpress theLine
  16.   global gSBTPress
  17.   asdf
  18.   set myChannel = integer(item 4 of theLine)
  19.   set myPressed = integer(item 6 of theLine)
  20.   
  21.   puppetSprite myChannel,TRUE
  22.   set the castNum of sprite myChannel to myPressed
  23.   updateStage
  24.   puppetSprite myChannel, false
  25.   
  26.   set t = the ticks
  27.   repeat while (t+30) > the ticks
  28.   end repeat
  29.   
  30.   if the mouseDown then 
  31.     set gSBTPress = 1
  32.     --put ">>> internal press-> doscript"
  33.     doScript ancestor
  34.   end if
  35.   
  36. end
  37.  
  38. on sbtrdoScript me
  39.   
  40.   global gSBTPress
  41.   
  42.   if gSBTPress then
  43.     --put ">>> sbt retrace exiting on an internal call" 
  44.     set gSBTPress = 0
  45.     exit
  46.   end if
  47.   
  48.   doScript ancestor
  49.   
  50. end doScript
  51.